hotplug scripts: better same_vm checks
authorKeir Fraser <keir.fraser@citrix.com>
Wed, 19 Aug 2009 12:11:33 +0000 (13:11 +0100)
committerKeir Fraser <keir.fraser@citrix.com>
Wed, 19 Aug 2009 12:11:33 +0000 (13:11 +0100)
commitb6cd10140c7d93c8ccf168c13a8455f2e878639c
tree2783dc050ad228834766b5cf120de5a415595b46
parentc88b1e06d5ad6d24b5cb0cb6f80ae35d94002ef5
hotplug scripts: better same_vm checks

currently the function same_vm in block-common.sh is the one
responsible for detecting if two block devices can be used at the same
time by two VMs. This can be allowed in few specific cases: when the
two VMs are actually the same VM and when the two VMs are the guest
and its stubdomain. We need to expand these exceptions to handle
properly save restore issues: this patch adds to the exceptions the
case when two VMs are the same VM because of save\restore races, and
when two VMs are the guest and the stubdomain of the previous guest,
again during save\restore.

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
tools/hotplug/Linux/block-common.sh